#include "common.h"

/*FLASH配置函数*/
void Flash_Config(void)
{
    flash_read_halfword((unsigned short *)WRITE_START_ADDR, (unsigned short *)&adaptor_parm, sizeof(adaptor_parm) / 2);

    if (adaptor_parm.part.BCP_Data != Backups_Data) {
        memory_set((unsigned char *)&adaptor_parm, 0, sizeof(adaptor_parm));
        init_ada_parm_and_store(&adaptor_parm);
    }
    /****ADD 2020 10 21*****/

    clear_adaptor_rsvd(&adaptor_parm);

    flash_ada_parm = adaptor_parm;
    flash_parm_to_configurable_parm();
}
